<template>
  <div>

    <div class="recommend">
      <WaveItem v-for="item in list " :key="item.uid" :dataObj="item" :showFollow="false"></WaveItem>
    </div>
  </div>
</template>

<script>
import { mapState } from 'vuex'
import WaveItem from '@/components/wave/waveItem.vue'
import http from '@/util/http'

export default {
  props: {
    WaveItem
  },
  data () {
    return {
      list: [],
      page: 1
    }
  },
  computed: {
    ...mapState(['serach'])
  },
  mounted () {
    // const { serachText } = this.$route.query
    console.log(this.serach)
    http.getarticle(this.serach, this.page).then(res => {
      this.list = res.data.serachList
      console.log(res.data)
    })
  }
}
</script>

<style lang="scss" scoped >
.recommend {
  display: flex;
  justify-content: space-between;
  height: auto;
  flex-wrap: wrap;

}

</style>
